package org.linlinjava.litemall.db.util;

import java.io.Serializable;
import java.util.List;

/**
 * @Author piao
 * @Date 2021/05/14
 */
public class PageResult<T> implements Serializable {
    private List<T> list;
    private int page;
    private int limit;
    private Long total;

    public List<T> getList() {
        return list;
    }

    public void setList(List<T> list) {
        this.list = list;
    }

    public int getPage() {
        return page;
    }

    public void setPage(int page) {
        this.page = page;
    }

    public int getLimit() {
        return limit;
    }

    public void setLimit(int limit) {
        this.limit = limit;
    }

    public Long getTotal() {
        return total;
    }

    public void setTotal(Long total) {
        this.total = total;
    }

    public PageResult(List<T> list, Long total) {
        this.list = list;
        this.total = total;
    }

    public PageResult(List<T> list, int page, int limit, Long total) {
        this.list = list;
        this.page = page;
        this.limit = limit;
        this.total = total;
    }
}
